Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

EWPP-4825: Preview extension for file patterns. #1517

Merged
merged 1 commit into from
Oct 28, 2024
Merged

EWPP-4825: Preview extension for file patterns. #1517

merged 1 commit into from
Oct 28, 2024

Conversation

intelektron
Copy link
Member

EWPP-4825

Description

Modification of the patterns to support additional properties.

@intelektron intelektron force-pushed the EWPP-4825 branch 3 times, most recently from 5a63726 to 06285e6 Compare October 14, 2024 09:39
@@ -18,6 +18,13 @@ file_translation:
size: "150000"
name: "document.pdf"
language_code: "en"
link_attributes:
Copy link
Member

@sergepavle sergepavle Oct 25, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why in the file_teaser pattern we add the possibility to add additional attributes but in the file_translation pattern we don't have a chance to specify extra_attributes for each translation?
I've checked in ewcms but didn't find that it works.
Is it intentional?
image

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've checked and seems like it is possible to add extra_attributes for file_translation items as well.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is limited by the fact, that file_translation has a different definition of the translations property. It does not allow to pass any additional data along with the translated file (it just takes a list of FileValueObject). So I can't pass the extra_attributes too. To change it, i would have to refactor the pattern and all references to it.

@upchuk upchuk merged commit c229a4e into 4.x Oct 28, 2024
1 check passed
@upchuk upchuk deleted the EWPP-4825 branch October 28, 2024 14:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants